print('defining sources and lumped element components')

voltage_sources = [{}]
current_sources = []
number_of_current_sources = 0
# diodes = []
# resistors = []
# inductors = []
# capacitors = []
waveforms={}
waveforms["sinusoidal"]=[{} for _ in range(2)]
waveforms["unit_step"]=[{}]
waveforms["gaussian"]=[{} for _ in range(2)]
waveforms["derivative_gaussian"]=[{}]
waveforms["cosine_modulated_gaussian"]=[{}]
# define source waveform types and parameters
waveforms["sinusoidal"][0]["frequency"] = 1e9 
waveforms["sinusoidal"][1]["frequency"] = 5e8 
waveforms["unit_step"][0]["start_time_step"] = 50 
waveforms["gaussian"][0]["number_of_cells_per_wavelength"] = 0 
waveforms["gaussian"][1]["number_of_cells_per_wavelength"] = 15 
waveforms["derivative_gaussian"][0]["number_of_cells_per_wavelength"] = 20 
# waveforms.cosine_modulated_gaussian(1).bandwidth = 1.5e9 
# waveforms.cosine_modulated_gaussian(1).modulation_frequency = 1.2e9 
waveforms["cosine_modulated_gaussian"][0]["bandwidth"] = 1.5e9 
waveforms["cosine_modulated_gaussian"][0]["modulation_frequency"] = 1.2e9 
# voltage sources 
# direction: 'xp', 'xn', 'yp', 'yn', 'zp', or 'zn'
# resistance : ohms, magitude   : volts
# voltage_sources(1).min_x = 0.028
# voltage_sources(1).min_y = 0.028
# voltage_sources(1).min_z = 0.028
# voltage_sources(1).max_x = 0.028
# voltage_sources(1).max_y = 0.028
# voltage_sources(1).max_z = 0.028+2.8e-3
# voltage_sources(1).min_x = 0
# voltage_sources(1).min_y = 1
# voltage_sources(1).min_z = 0.5
# voltage_sources(1).max_x = 0
# voltage_sources(1).max_y = 1
# voltage_sources(1).max_z = 0.5+10e-2

voltage_sources[0]["direction"] = 'zp'
voltage_sources[0]["resistance"] = 40
voltage_sources[0]["magnitude"] = 1
# voltage_sources(1).waveform_type = 'derivative_gaussian'
voltage_sources[0]["waveform_type"] = 'cosine_modulated_gaussian'
voltage_sources[0]["frequency"] = 3e8
voltage_sources[0]["waveform_index"] = 1
print(waveforms["sinusoidal"])